package com.example.common.bean;

import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.apache.poi.ss.formula.functions.T;

/**
 * @author ZhengDing
 * @date 2022/1/28 9:33
 */

@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
public class R<T> {
    private Integer code;
    private String msg;
    private T data;

    public static <T> R<T> OK(T data) {
        return new R(0, "success", data);
    }
    public static <T> R<T> OK() {
        return new R(0, "success", "");
    }
    
}
